package com.xiaoyu.chap3.GC;

/**
 * Created by xiaoyu on 16/4/6.
 * VM args:-verbose:gc -Xms20M -Xmx20M -Xmn10M -XX:+PrintGCDetails -XX:SurvivorRatio=8 -XX:+UseSerialGC -XX:PretenureSizeThreshold=3145728
 * -XX:PretenureSizeThreshold参数令大小大于设定值的对象直接在老年代分配
 */
public class TestPretenureSizeThreshold {

    private static final int _1MB = 1024*1024;
    
    public static void testPretenureSizeThreshould(){
        byte[] allocation;
        allocation = new byte[4*_1MB];
    }

    public static void main(String[] args) {
        testPretenureSizeThreshould();
    }

}
